///图片路径
class ImagePathUtils {
  ///获取类库名称
  static final String packagesName = "game";

  //获取本类库的包名路径
  static String getPackagesPath([String? path = null]) {
    if (path == null) {
      return 'packages/$packagesName/';
    } else {
      return 'packages/$packagesName/' + path;
    }
  }

  ///获取images目录图片
  static String getPathWithImage(String imageName) {
    return getPackagesPath() + 'assets/images/$imageName';
  }

  ///获取images/ball目录图片
  static String getPathWithImageBall(String imageName) {
    return getPackagesPath() + 'assets/images/ball/$imageName';
  }

  ///获取images/brick目录图片
  static String getPathWithImageBrick(String imageName) {
    return getPackagesPath() + 'assets/images/brick/$imageName';
  }
}
